<template>
  <div>
    <router-view></router-view>
    <div class="nav" v-show="$store.state.flag">
      <router-link to="/home">
        <span class="iconfont  iconfont-shouye"></span>
        <br />主页
      </router-link>
      <router-link to="/classify/1">
        <span class="iconfont  iconfont-24gf-playlistHeart3"></span>
        <br />分类
      </router-link>
      <router-link to="/shoppingcar">
        <span class="iconfont  iconfont-gouwucheman"></span>
        <br />购物车
      </router-link>
      <router-link to="/mine">
        <span class="iconfont  iconfont-wode"></span>
        <br />我的
      </router-link>
    </div>
  </div>
</template>

<style lang="scss" scoped>
.nav {
  height: 1.2rem;
  position: fixed;
  left: 0;
  bottom: 0;
  display: flex;
  width: 100%;
  a {
    flex: 1;
    text-align: center;
    font-size: 10px;
    .iconfont{
      font-size: 30px;
    }
  }
  padding-top: 10px;
  padding-bottom: 10px;
  background-color: white;
}
a.router-link-active {
    color: #ff5f16;
  }

</style>
